package com.milhouz.wormdroid.gl.model.hud;

import android.graphics.Paint;

import com.milhouz.wormdroid.gl.model.text.TextSprite;

public class SelectedBotHudSprite extends TextSprite {

	private int mBotId;
	private String mBotName;
	private int mBotPower;
	
	public SelectedBotHudSprite(int botId, String botName, int botPower, float x, float y, Paint paint) {
		super(HudSpriteNames.PLAYER_SPRITE, x, y, paint);
		this.mBotId = botId;
		this.mBotName = botName;
		this.mBotPower = botPower;
		updateHud();
	}

	public void update(String... values) {
		this.mBotId = Integer.valueOf(values[0]);
		this.mBotName = values[1];
		this.mBotPower = Integer.valueOf(values[2]);
		updateHud();
	}
	
	private void updateHud() {
			super.setText(mBotName + " " + mBotId + "  -  " + mBotPower + "%");
	}
	
}
